package com.smarth.zhizulian.adapter;

import android.content.Context;
import android.support.v4.view.PagerAdapter;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
import android.widget.TextView;

import com.smarth.zhizulian.R;
import com.smarth.zhizulian.app.BaseConfig;
import com.smarth.zhizulian.entity.EventBean;
import com.ogaclejapan.smarttablayout.SmartTabLayout;

import org.simple.eventbus.EventBus;

import pl.droidsonroids.gif.GifDrawable;
import pl.droidsonroids.gif.GifImageView;

/**
 * Created by 18865 on 2018/2/1.
 */

public class MessageCenterTabProvider implements SmartTabLayout.TabProvider {
    private Context mContext;

    public MessageCenterTabProvider(Context mContext) {
        this.mContext = mContext;
    }

    @Override
    public View createTabView(ViewGroup container, final int position, PagerAdapter adapter) {
        View view = LayoutInflater.from(mContext).inflate(R.layout.tab_message, container, false);
        TextView tv_text = view.findViewById(R.id.tv_text);
        tv_text.setText(adapter.getPageTitle(position));
        return view;
    }
}
